home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Source Code / Visual Basic Source Code.iso / vbsource / msword1a / mdidesk.frm (.txt) < prev    next >
Encoding:
Visual Basic Form  |  1999-08-27  |  2.1 KB  |  66 lines

  1. VERSION 5.00
  2. Begin VB.MDIForm MDIDesk 
  3.    BackColor       =   &H8000000C&
  4.    Caption         =   "Vb6/WebBrowser Automation"
  5.    ClientHeight    =   3510
  6.    ClientLeft      =   1260
  7.    ClientTop       =   630
  8.    ClientWidth     =   5280
  9.    NegotiateToolbars=   0   'False
  10.    ScrollBars      =   0   'False
  11.    Begin VB.Menu mnuFileMenu 
  12.       Caption         =   "&File"
  13.       Begin VB.Menu mnuFile 
  14.          Caption         =   "&New"
  15.          Index           =   0
  16.          Shortcut        =   ^N
  17.       End
  18.       Begin VB.Menu mnuFile 
  19.          Caption         =   "&Demo"
  20.          Index           =   1
  21.       End
  22.       Begin VB.Menu mnuFile 
  23.          Caption         =   "-"
  24.          Index           =   2
  25.       End
  26.       Begin VB.Menu mnuFile 
  27.          Caption         =   "E&xit"
  28.          Index           =   3
  29.       End
  30.    End
  31. Attribute VB_Name = "MDIDesk"
  32. Attribute VB_GlobalNameSpace = False
  33. Attribute VB_Creatable = False
  34. Attribute VB_PredeclaredId = True
  35. Attribute VB_Exposed = False
  36. Option Explicit
  37. ' WbrWord v2.00 (Vb6) Apr 1999 contact markb@orionstudios.com
  38. ' Demonstrates using WebBrowser Control as container for MS Word Document
  39. ' WbrWord.frm is managed by (this) MDI Form to demonstrate that
  40. '   WinWord is started when a Word document is loaded into the frmWbrWord
  41. '   instance and remains active until the frmWbrWord instance is closed.
  42. '   This can be confirmed using Ctrl-Alt-Del to view the task list.
  43. ' See Header comments in WbrWord.frm
  44. '=================================================================================
  45. Private Sub MDIForm_Load()
  46.     Me.Move 1200, 0, 9600, 8400
  47. End Sub
  48. Private Sub mnuFile_Click(Index As Integer)
  49.     On Error Resume Next
  50.     Select Case Index
  51.         Case 0  ' Blank WebBrowser Form for loading Word Document
  52.             With New frmWbrWord
  53.                 .Show
  54.             End With
  55.             
  56.         Case 1  ' Demo manipulation of Word Document
  57.             With New frmWbrWordDemo
  58.                 .Show
  59.             End With
  60.             
  61.         Case 3  ' Exit
  62.             Unload Me
  63.        
  64.     End Select
  65. End Sub
  66.